package com.example.demo.Enum;


public enum ResultStatus {

    SUCCESS( 200, "OK"),

    ERROR( 500, "Error"),;


    /** 业务异常码 */
    private Integer code;
    /** 业务异常信息描述 */
    private String message;

    ResultStatus(Integer code, String message) {

        this.code = code;
        this.message = message;
    }


    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }

    @Override
    public String toString() {
        return "ResultStatus{" +
                ", code=" + code +
                ", message='" + message + '\'' +
                '}';
    }
}
